package com.smooth.dao.gen;

import com.smooth.dao.gen.bean.BizStudent;
import com.smooth.dao.gen.bean.BizStudentExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface BizStudentMapper {
    /** biz_student */
    @SelectProvider(type=BizStudentSqlProvider.class, method="countByExample")
    long countByExample(BizStudentExample example);

    /** biz_student */
    @DeleteProvider(type=BizStudentSqlProvider.class, method="deleteByExample")
    int deleteByExample(BizStudentExample example);

    /** biz_student */
    @Delete({
        "delete from biz_student",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    int deleteByPrimaryKey(String id);

    /** biz_student */
    @Insert({
        "insert into biz_student (id, stu_name, ",
        "stu_height, stu_weight, ",
        "job_status, tel_no, ",
        "password, gender, ",
        "percent, subject_id, ",
        "subject_name, jifen_all_amount, ",
        "jifen_amount, pic_head, ",
        "pic_body, pic_nomake, ",
        "pic_life, college_level, ",
        "faculty, stu_nation, ",
        "birthday, native_palce, ",
        "domicile, province_id, ",
        "province_name, city_id, ",
        "city_name, area_id, ",
        "area_name, sch_id, ",
        "sch_name, high_sch_name, ",
        "mid_sch_name, sc_faculty, ",
        "ruxue_time, xueke_type, ",
        "create_by, create_date, ",
        "update_by, update_date, ",
        "del_flag)",
        "values (#{id,jdbcType=VARCHAR}, #{stuName,jdbcType=VARCHAR}, ",
        "#{stuHeight,jdbcType=DOUBLE}, #{stuWeight,jdbcType=DOUBLE}, ",
        "#{jobStatus,jdbcType=INTEGER}, #{telNo,jdbcType=VARCHAR}, ",
        "#{password,jdbcType=VARCHAR}, #{gender,jdbcType=SMALLINT}, ",
        "#{percent,jdbcType=DOUBLE}, #{subjectId,jdbcType=VARCHAR}, ",
        "#{subjectName,jdbcType=VARCHAR}, #{jifenAllAmount,jdbcType=INTEGER}, ",
        "#{jifenAmount,jdbcType=INTEGER}, #{picHead,jdbcType=VARCHAR}, ",
        "#{picBody,jdbcType=VARCHAR}, #{picNomake,jdbcType=VARCHAR}, ",
        "#{picLife,jdbcType=VARCHAR}, #{collegeLevel,jdbcType=VARCHAR}, ",
        "#{faculty,jdbcType=VARCHAR}, #{stuNation,jdbcType=VARCHAR}, ",
        "#{birthday,jdbcType=DATE}, #{nativePalce,jdbcType=VARCHAR}, ",
        "#{domicile,jdbcType=VARCHAR}, #{provinceId,jdbcType=VARCHAR}, ",
        "#{provinceName,jdbcType=VARCHAR}, #{cityId,jdbcType=VARCHAR}, ",
        "#{cityName,jdbcType=VARCHAR}, #{areaId,jdbcType=VARCHAR}, ",
        "#{areaName,jdbcType=VARCHAR}, #{schId,jdbcType=VARCHAR}, ",
        "#{schName,jdbcType=VARCHAR}, #{highSchName,jdbcType=VARCHAR}, ",
        "#{midSchName,jdbcType=VARCHAR}, #{scFaculty,jdbcType=VARCHAR}, ",
        "#{ruxueTime,jdbcType=TIMESTAMP}, #{xuekeType,jdbcType=SMALLINT}, ",
        "#{createBy,jdbcType=VARCHAR}, #{createDate,jdbcType=TIMESTAMP}, ",
        "#{updateBy,jdbcType=VARCHAR}, #{updateDate,jdbcType=TIMESTAMP}, ",
        "#{delFlag,jdbcType=SMALLINT})"
    })
    int insert(BizStudent record);

    /** biz_student */
    @InsertProvider(type=BizStudentSqlProvider.class, method="insertSelective")
    int insertSelective(BizStudent record);

    /** biz_student */
    @SelectProvider(type=BizStudentSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="id", property="id", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="stu_name", property="stuName", jdbcType=JdbcType.VARCHAR),
        @Result(column="stu_height", property="stuHeight", jdbcType=JdbcType.DOUBLE),
        @Result(column="stu_weight", property="stuWeight", jdbcType=JdbcType.DOUBLE),
        @Result(column="job_status", property="jobStatus", jdbcType=JdbcType.INTEGER),
        @Result(column="tel_no", property="telNo", jdbcType=JdbcType.VARCHAR),
        @Result(column="password", property="password", jdbcType=JdbcType.VARCHAR),
        @Result(column="gender", property="gender", jdbcType=JdbcType.SMALLINT),
        @Result(column="percent", property="percent", jdbcType=JdbcType.DOUBLE),
        @Result(column="subject_id", property="subjectId", jdbcType=JdbcType.VARCHAR),
        @Result(column="subject_name", property="subjectName", jdbcType=JdbcType.VARCHAR),
        @Result(column="jifen_all_amount", property="jifenAllAmount", jdbcType=JdbcType.INTEGER),
        @Result(column="jifen_amount", property="jifenAmount", jdbcType=JdbcType.INTEGER),
        @Result(column="pic_head", property="picHead", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_body", property="picBody", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_nomake", property="picNomake", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_life", property="picLife", jdbcType=JdbcType.VARCHAR),
        @Result(column="college_level", property="collegeLevel", jdbcType=JdbcType.VARCHAR),
        @Result(column="faculty", property="faculty", jdbcType=JdbcType.VARCHAR),
        @Result(column="stu_nation", property="stuNation", jdbcType=JdbcType.VARCHAR),
        @Result(column="birthday", property="birthday", jdbcType=JdbcType.DATE),
        @Result(column="native_palce", property="nativePalce", jdbcType=JdbcType.VARCHAR),
        @Result(column="domicile", property="domicile", jdbcType=JdbcType.VARCHAR),
        @Result(column="province_id", property="provinceId", jdbcType=JdbcType.VARCHAR),
        @Result(column="province_name", property="provinceName", jdbcType=JdbcType.VARCHAR),
        @Result(column="city_id", property="cityId", jdbcType=JdbcType.VARCHAR),
        @Result(column="city_name", property="cityName", jdbcType=JdbcType.VARCHAR),
        @Result(column="area_id", property="areaId", jdbcType=JdbcType.VARCHAR),
        @Result(column="area_name", property="areaName", jdbcType=JdbcType.VARCHAR),
        @Result(column="sch_id", property="schId", jdbcType=JdbcType.VARCHAR),
        @Result(column="sch_name", property="schName", jdbcType=JdbcType.VARCHAR),
        @Result(column="high_sch_name", property="highSchName", jdbcType=JdbcType.VARCHAR),
        @Result(column="mid_sch_name", property="midSchName", jdbcType=JdbcType.VARCHAR),
        @Result(column="sc_faculty", property="scFaculty", jdbcType=JdbcType.VARCHAR),
        @Result(column="ruxue_time", property="ruxueTime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="xueke_type", property="xuekeType", jdbcType=JdbcType.SMALLINT),
        @Result(column="create_by", property="createBy", jdbcType=JdbcType.VARCHAR),
        @Result(column="create_date", property="createDate", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="update_by", property="updateBy", jdbcType=JdbcType.VARCHAR),
        @Result(column="update_date", property="updateDate", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="del_flag", property="delFlag", jdbcType=JdbcType.SMALLINT)
    })
    List<BizStudent> selectByExample(BizStudentExample example);

    /** biz_student */
    @Select({
        "select",
        "id, stu_name, stu_height, stu_weight, job_status, tel_no, password, gender, ",
        "percent, subject_id, subject_name, jifen_all_amount, jifen_amount, pic_head, ",
        "pic_body, pic_nomake, pic_life, college_level, faculty, stu_nation, birthday, ",
        "native_palce, domicile, province_id, province_name, city_id, city_name, area_id, ",
        "area_name, sch_id, sch_name, high_sch_name, mid_sch_name, sc_faculty, ruxue_time, ",
        "xueke_type, create_by, create_date, update_by, update_date, del_flag",
        "from biz_student",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    @Results({
        @Result(column="id", property="id", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="stu_name", property="stuName", jdbcType=JdbcType.VARCHAR),
        @Result(column="stu_height", property="stuHeight", jdbcType=JdbcType.DOUBLE),
        @Result(column="stu_weight", property="stuWeight", jdbcType=JdbcType.DOUBLE),
        @Result(column="job_status", property="jobStatus", jdbcType=JdbcType.INTEGER),
        @Result(column="tel_no", property="telNo", jdbcType=JdbcType.VARCHAR),
        @Result(column="password", property="password", jdbcType=JdbcType.VARCHAR),
        @Result(column="gender", property="gender", jdbcType=JdbcType.SMALLINT),
        @Result(column="percent", property="percent", jdbcType=JdbcType.DOUBLE),
        @Result(column="subject_id", property="subjectId", jdbcType=JdbcType.VARCHAR),
        @Result(column="subject_name", property="subjectName", jdbcType=JdbcType.VARCHAR),
        @Result(column="jifen_all_amount", property="jifenAllAmount", jdbcType=JdbcType.INTEGER),
        @Result(column="jifen_amount", property="jifenAmount", jdbcType=JdbcType.INTEGER),
        @Result(column="pic_head", property="picHead", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_body", property="picBody", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_nomake", property="picNomake", jdbcType=JdbcType.VARCHAR),
        @Result(column="pic_life", property="picLife", jdbcType=JdbcType.VARCHAR),
        @Result(column="college_level", property="collegeLevel", jdbcType=JdbcType.VARCHAR),
        @Result(column="faculty", property="faculty", jdbcType=JdbcType.VARCHAR),
        @Result(column="stu_nation", property="stuNation", jdbcType=JdbcType.VARCHAR),
        @Result(column="birthday", property="birthday", jdbcType=JdbcType.DATE),
        @Result(column="native_palce", property="nativePalce", jdbcType=JdbcType.VARCHAR),
        @Result(column="domicile", property="domicile", jdbcType=JdbcType.VARCHAR),
        @Result(column="province_id", property="provinceId", jdbcType=JdbcType.VARCHAR),
        @Result(column="province_name", property="provinceName", jdbcType=JdbcType.VARCHAR),
        @Result(column="city_id", property="cityId", jdbcType=JdbcType.VARCHAR),
        @Result(column="city_name", property="cityName", jdbcType=JdbcType.VARCHAR),
        @Result(column="area_id", property="areaId", jdbcType=JdbcType.VARCHAR),
        @Result(column="area_name", property="areaName", jdbcType=JdbcType.VARCHAR),
        @Result(column="sch_id", property="schId", jdbcType=JdbcType.VARCHAR),
        @Result(column="sch_name", property="schName", jdbcType=JdbcType.VARCHAR),
        @Result(column="high_sch_name", property="highSchName", jdbcType=JdbcType.VARCHAR),
        @Result(column="mid_sch_name", property="midSchName", jdbcType=JdbcType.VARCHAR),
        @Result(column="sc_faculty", property="scFaculty", jdbcType=JdbcType.VARCHAR),
        @Result(column="ruxue_time", property="ruxueTime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="xueke_type", property="xuekeType", jdbcType=JdbcType.SMALLINT),
        @Result(column="create_by", property="createBy", jdbcType=JdbcType.VARCHAR),
        @Result(column="create_date", property="createDate", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="update_by", property="updateBy", jdbcType=JdbcType.VARCHAR),
        @Result(column="update_date", property="updateDate", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="del_flag", property="delFlag", jdbcType=JdbcType.SMALLINT)
    })
    BizStudent selectByPrimaryKey(String id);

    /** biz_student */
    @UpdateProvider(type=BizStudentSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") BizStudent record, @Param("example") BizStudentExample example);

    /** biz_student */
    @UpdateProvider(type=BizStudentSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") BizStudent record, @Param("example") BizStudentExample example);

    /** biz_student */
    @UpdateProvider(type=BizStudentSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(BizStudent record);

    /** biz_student */
    @Update({
        "update biz_student",
        "set stu_name = #{stuName,jdbcType=VARCHAR},",
          "stu_height = #{stuHeight,jdbcType=DOUBLE},",
          "stu_weight = #{stuWeight,jdbcType=DOUBLE},",
          "job_status = #{jobStatus,jdbcType=INTEGER},",
          "tel_no = #{telNo,jdbcType=VARCHAR},",
          "password = #{password,jdbcType=VARCHAR},",
          "gender = #{gender,jdbcType=SMALLINT},",
          "percent = #{percent,jdbcType=DOUBLE},",
          "subject_id = #{subjectId,jdbcType=VARCHAR},",
          "subject_name = #{subjectName,jdbcType=VARCHAR},",
          "jifen_all_amount = #{jifenAllAmount,jdbcType=INTEGER},",
          "jifen_amount = #{jifenAmount,jdbcType=INTEGER},",
          "pic_head = #{picHead,jdbcType=VARCHAR},",
          "pic_body = #{picBody,jdbcType=VARCHAR},",
          "pic_nomake = #{picNomake,jdbcType=VARCHAR},",
          "pic_life = #{picLife,jdbcType=VARCHAR},",
          "college_level = #{collegeLevel,jdbcType=VARCHAR},",
          "faculty = #{faculty,jdbcType=VARCHAR},",
          "stu_nation = #{stuNation,jdbcType=VARCHAR},",
          "birthday = #{birthday,jdbcType=DATE},",
          "native_palce = #{nativePalce,jdbcType=VARCHAR},",
          "domicile = #{domicile,jdbcType=VARCHAR},",
          "province_id = #{provinceId,jdbcType=VARCHAR},",
          "province_name = #{provinceName,jdbcType=VARCHAR},",
          "city_id = #{cityId,jdbcType=VARCHAR},",
          "city_name = #{cityName,jdbcType=VARCHAR},",
          "area_id = #{areaId,jdbcType=VARCHAR},",
          "area_name = #{areaName,jdbcType=VARCHAR},",
          "sch_id = #{schId,jdbcType=VARCHAR},",
          "sch_name = #{schName,jdbcType=VARCHAR},",
          "high_sch_name = #{highSchName,jdbcType=VARCHAR},",
          "mid_sch_name = #{midSchName,jdbcType=VARCHAR},",
          "sc_faculty = #{scFaculty,jdbcType=VARCHAR},",
          "ruxue_time = #{ruxueTime,jdbcType=TIMESTAMP},",
          "xueke_type = #{xuekeType,jdbcType=SMALLINT},",
          "create_by = #{createBy,jdbcType=VARCHAR},",
          "create_date = #{createDate,jdbcType=TIMESTAMP},",
          "update_by = #{updateBy,jdbcType=VARCHAR},",
          "update_date = #{updateDate,jdbcType=TIMESTAMP},",
          "del_flag = #{delFlag,jdbcType=SMALLINT}",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    int updateByPrimaryKey(BizStudent record);
}